/**
 * Created by chemeng on 2017/3/27.
 */
var app = angular.module("registerApp", []);
app.controller("registerController", function ($scope, $http) {
    $scope.user = {};
    $scope.register = function () {
        debugger;
        $http({
            method: "POST",
            data: $scope.user,
            //url: 'http://localhost:8080/rest/register'
            url: '/rest/register'
        }).then(function onSuccess(responce) {
                console.log(responce.data);
            },
            function onError(response) {
                console.log(response.data);
            });
    };
});